﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using TracNghiemTinHocDaiCuong.ThucThe;
using TracNghiemTinHocDaiCuong.BIZ;
 

namespace TracNghiemTinHocDaiCuong
{
    public partial class ThemChuDe : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        protected void btnThem_Click(object sender, EventArgs e)
        {
            ChuDe chuDe = new ChuDe();
            chuDe.TenCD = txtTenChuDe.Text;
            chuDe.GhiChu = txtGhiChu.Text;
            ChuDeBIZ.Them(chuDe);
            lblThongBao.Text = "Bạn đã thêm " + txtTenChuDe.Text + " thành công";
        }

        protected void btnXoaTuKhoa_Click(object sender, EventArgs e)
        {
            txtTenChuDe.Text = "";
            txtGhiChu.Text = "";
        }

        protected void btnQuayLai_Click(object sender, EventArgs e)
        {
            Response.Redirect("QuanLyChuDe.aspx");
        }
    }
}